package cn.tedu.csmall.server.controller;

import cn.tedu.csmall.server.pojo.dto.AttributeTemplateAddNewDTO;
import cn.tedu.csmall.server.service.impl.AttributeTemplateService;
import cn.tedu.csmall.server.web.JsonResult;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author lixin
 * @Date 2022/9/13
 */
@RestController
@RequestMapping("attribute-template")
@Api(tags = "4.属性模板模块")
public class AttributeTemplateController {
    @Autowired
    private AttributeTemplateService attributeTemplateService;
    @ApiOperation("添加属性模板")
    @PostMapping("add-new")
    public JsonResult addNew(AttributeTemplateAddNewDTO attributeTemplateAddNewDTO){
        attributeTemplateService.addNew(attributeTemplateAddNewDTO);
        return JsonResult.ok();
    }


}
